package uy.com.tsi2G7.superbet.event.dao;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

import uy.com.tsi2G7.superbet.event.Event;
import uy.com.tsi2G7.superbet.event.EventMarket;
import uy.com.tsi2G7.superbet.event.EventMarketResult;
import uy.com.tsi2G7.superbet.event.EventType;

public interface EventStore {

	public List<Event> getAllEvents();
	
	public List<EventType> getAllEventTypes();

	public List<EventMarket> getCurrentMarketsByEventId(Long eventId, Long eventTypeId);

	public List<EventMarketResult> getMarketsWithPendingResults(long marketId);

	public EventMarket getMarketById(long marketId);

	void storeMarketResult(long marketResultId, String marketResultName,
			long marketId, long eventId, long eventTypeId, BigDecimal amount)
			throws ObjectAlreadyExistsException;

	public Event getEventById(long eventId);
	
	public EventType getEventTypeById(long eventTypeId);

	public void storeEvent(Long eventTypeId, long eventId, String eventInputName)throws ObjectAlreadyExistsException;

	public void storeMarket(Long eventId, Long eventTypeId, long marketId,
			String marketInputName, Date marketDate) throws ObjectAlreadyExistsException;

	public List<EventMarketResult> getMarketResultsById(List<Long> ids);

	public List<EventMarket> getManualSourceMarketsWithPendingResults();

	public void mergeResult(EventMarketResult eventMarketResult);

}


